#!/usr/bin/env python3
# -*- coding: utf-8 -*-

"""
王者荣耀
"""

class Role:

    def __init__(self, name, blood, destroy):
        self.name = name
        self.blood = blood
        self.destroy = destroy

    def hit(self, other):
        # self, other : Role
        other.blood -= self.destroy
        print(self.name, '打击', other.name)
        # print(other.name, '剩下血量', other.blood)


class Hero(Role):
    def __init__(self, name, blood, destroy, weapon):
        super(Hero, self).__init__(name, blood, destroy)
        self.weapon = weapon

    def lift(self, b=10, d=1):
        self.blood += b
        self.destroy += d

h1 = Hero('貂蝉', 100, 10, '短剑')
h2 = Hero('曹操', 100, 20, '倚天剑')

h2.hit(h1)

